exports.callback = function(req, res, next) {
	server.Models.Device.findOne({
		hwAddress : req.params.device
	}, function(e, device) {
		server.Models.Port.find({
			hwAddress : req.params.device
		}, function(e, ports) {
			res.render('editDevice.jade', {
				pageTitle : 'Device Configuration',
				device : device,
				ports : ports,
				pretty : true
			});
		});
	});
};

exports.path = '/devices/:device';
exports.method = 'get';
